/*
 * @Author: zhangwei 1405298045@qq.com
 * @Date: 2022-03-31 14:54:49
 * @LastEditTime: 2022-04-02 14:19:03
 * @LastEditors: zhangwei 1405298045@qq.com
 * @Description:
 * @FilePath: /ll-fe-mp-dyfx/src/api/login.js
 *
 */
import { GET, POST } from '@/service';
import Store from '@/store';
/**
 * 解析用户 oppid（特殊接口方式）
 * @param params
 */

export const getWxUuid = (otherParams) => {
	const url = '/api/login/mini/session';

	return GET(url, otherParams);
};

export const getUserToken = (otherParams) => {
	const url = '/api/login/phone/decrypt';

	return POST(url, otherParams);
};
/**
 * 获取用户抖音信息
 * @param
 */
export const getBytedance = (otherParams) => {
	const url = '/api/userInfo/bytedance';

	return GET(url, otherParams);
};

export const setBatchSave = (otherParams) => {
	const url = '/api/userChannel/batchSave';

	return POST(url, otherParams);
};
/**
 * 手机号登陆
 * */
export const mobileLogin = (otherParams) => {
	const url = '/api/login/mobile/phone';

	return POST(url, otherParams);
};
/**
 * 发送验证码
 * */
export const sendCode = (otherParams) => {
	const url = '/api/login/sendCode';

	return GET(url, otherParams);
};
/**
 * 昵称-头像设置
 * */
export const setUserInfo = (otherParams) => {
	const url = '/api/login/setting';

	return POST(url, otherParams);
};
